﻿<%@ Control Language="VB" AutoEventWireup="false" CodeFile="QueryHonorCert.ascx.vb" Inherits="WebForm_QueryHonorCert" %>
<%@ Register Namespace="My" TagPrefix="cc1" %>
<%@ Register src="~/WebForm/CommonControl/VolunteerQueryControl.ascx" tagname="VolunteerQueryControl" tagprefix="uc1" %>

<uc1:VolunteerQueryControl ID="VolunteerQueryControl1" runat="server" LoadOnStartUp="true" />

<table>
<%--    <tr>
        <td align="right">
            <asp:Label ID="lblTownID" runat="server" meta:resourcekey="lblTownID"></asp:Label>
        </td>
        <td align="left">
            <asp:DropDownList ID="ddlTownID" runat="server" AutoPostBack="true">
            </asp:DropDownList>
        </td> 
        <td align="right">
            <asp:Label ID="lblVillageID" runat="server" meta:resourcekey="lblVillageID"></asp:Label>
        </td>
        <td align="left">
            <asp:DropDownList ID="ddlVillageID" runat="server" AutoPostBack="false">
            </asp:DropDownList>
        </td>        
    </tr>--%>
<%--    <tr>
        <asp:UpdatePanel ID="upOrganizationID" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
                <td align="right">
                    <asp:Label ID="lblOrganizationID" runat="server" Text="<%$ Resources:OrganizationID %>"></asp:Label>
                </td>
                <td align="left">
                    <asp:DropDownList ID="ddlOrganizationID" runat="server" AutoPostBack="true"  DataTextField="OrganizationName" DataValueField="UOrganizationID" OnSelectedIndexChanged="ddlOrganizationID_SelectedIndexChanged">
                    </asp:DropDownList>
                </td>
                <asp:PlaceHolder ID="phVOrganizationID" runat="server" Visible="false">
                    <td align="right">
                        <asp:Label ID="lblVOrganizationID" runat="server" Text="<%$ Resources:VOrganizationID %>"></asp:Label>
                    </td>
                    <td align="left">
                        <asp:DropDownList ID="ddlVOrganizationID" runat="server" AutoPostBack="false">
                        </asp:DropDownList>
                    </td>
                </asp:PlaceHolder>
            </ContentTemplate>
        </asp:UpdatePanel>
     </tr>--%>
<%--    <tr>
        <td align="right">
            <asp:Label ID="lblVolunteerID" runat="server" meta:resourcekey="lblVolunteerID"></asp:Label></td>
        <td align="left">
            <asp:TextBox ID="txtVolunteerID" runat="server"></asp:TextBox></td>
        <td align="right">
            <asp:Label ID="lblVolunteerName" runat="server" meta:resourcekey="lblVolunteerName"></asp:Label>
        </td>
        <td align="left">
            <asp:TextBox ID="txtVolunteerName" runat="server"></asp:TextBox>
        </td>
    </tr>--%>
    <tr>
        <td align="right">
            <asp:Label ID="lblEndDate" runat="server" meta:resourcekey="lblEndDate"></asp:Label></td>
        <td align="left" colspan="3">
            <My:CalendarTextBox ID="txtEffectiveStartDate" runat="server" />
            ~
            <My:CalendarTextBox ID="txtEffectiveEndDate" runat="server" MaxYearSteps="4" />            
        </td>
    </tr>    
<%--    <tr>
        <td align="right">
            <asp:Label ID="lblIssueDate" runat="server" meta:resourcekey="lblIssueDate"></asp:Label></td>
        <td align="left" colspan="3">
            <My:CalendarTextBox ID="txtIssueStartDate" runat="server" />
            ~
            <My:CalendarTextBox ID="txtIssueEndDate" runat="server" />            
        </td>
    </tr>--%>
    <tr>
        <td align="right">
        </td>
        <td align="left" colspan="3">
            <asp:Button ID="btnQuery" runat="server" meta:resourcekey="btnQuery" />            
    </tr>
</table>
<br />
<My:MyGridView ID="gv" runat="server" SkinID="pager" AllowHoverSelect="false" AllowHoverEffect="true"
    meta:resourcekey="gv" MySortDirection="Ascending" AllowSorting="True">
    <Columns>
     <My:VolunteerIDBoundField DataField="VolunteerID" meta:resourcekey="bfVolunteerID"
            ReadOnly="True" SortExpression="v.VolunteerID" />
<%--        <asp:BoundField DataField="VolunteerID" meta:resourcekey="bfVolunteerID" SortExpression="v.VolunteerID" />
--%>        <asp:BoundField DataField="VolunteerName" meta:resourcekey="bfVolunteerName" SortExpression="v.VolunteerName" />
        <asp:BoundField DataField="HonorCertCode" meta:resourcekey="bfHonorCertCode" SortExpression="hc.HonorCertCode" />
        <asp:TemplateField meta:resourcekey="bfEndDate" SortExpression="HC.EndDate">
            <itemtemplate>
                <asp:Label runat="server" Text='<%# Bind("EndDate") %>' id="Label1"></asp:Label>
                <asp:Label runat="server" Text='<%# Bind("HonorCertID") %>' id="lblHonorCertID" Visible="false"></asp:Label>
            </itemtemplate>
            <itemstyle horizontalalign="Center" />
        </asp:TemplateField>
        <asp:BoundField DataField="Comment" meta:resourcekey="bfComment" >
            <headerstyle width="100px" />
        </asp:BoundField> 
        <asp:TemplateField>
                   <itemtemplate>
                                 <asp:LinkButton ID="lknSelect" runat="server" meta:resourcekey="lknSelect" CommandName="Select"></asp:LinkButton>
                   </itemtemplate>
        </asp:TemplateField>
        
    </Columns>
</My:MyGridView>